import 'package:plugin_platform_interface/plugin_platform_interface.dart';

import 'camera_product_plugin_method_channel.dart';

abstract class CameraProductPluginPlatform extends PlatformInterface {
  /// Constructs a CameraProductPluginPlatform.
  CameraProductPluginPlatform() : super(token: _token);

  static final Object _token = Object();

  static CameraProductPluginPlatform _instance =
      MethodChannelCameraProductPlugin();

  /// The default instance of [CameraProductPluginPlatform] to use.
  ///
  /// Defaults to [MethodChannelCameraProductPlugin].
  static CameraProductPluginPlatform get instance => _instance;

  /// Platform-specific implementations should set this with their own
  /// platform-specific class that extends [CameraProductPluginPlatform] when
  /// they register themselves.
  static set instance(CameraProductPluginPlatform instance) {
    PlatformInterface.verifyToken(instance, _token);
    _instance = instance;
  }

  Future<String?> getPlatformVersion() {
    throw UnimplementedError('platformVersion() has not been implemented.');
  }

  //====================以下是新添加的==============================
  void onListening(void Function(dynamic event) onData) {
    throw UnimplementedError('onListening has not been implemented.');
  }

  Future<String?> initCameraSDK() {
    throw UnimplementedError('initCameraSDK() has not been implemented.');
  }

  /// 扫描蓝牙设备
  Future<String?> scanBluetooth() {
    throw UnimplementedError('scanBluetooth() has not been implemented.');
  }

  ///连接蓝牙
  Future<String?> connectBluetooth(String deviceJson) {
    throw UnimplementedError('connectBluetooth() has not been implemented.');
  }

  ///扫描WIFI
  Future<String?> scanWIFI() {
    throw UnimplementedError('scanWIFI() has not been implemented.');
  }

  ///连接WIFI
  Future<String?> connectWIFI(String wifiJson) {
    throw UnimplementedError('connectWIFI() has not been implemented.');
  }

  ///拍照
  Future<String?> takePhoto() {
    throw UnimplementedError('takePhoto() has not been implemented.');
  }

  Future<String?> removeCameraListener() {
    throw UnimplementedError(
        'removeCameraListener() has not been implemented.');
  }

  Future<String?> disConnectBluetooth() {
    throw UnimplementedError('disConnectBluetooth() has not been implemented.');
  }

  ///获取当前已连接设备
  Future<String?> getCurrentDevice() async {
    throw UnimplementedError('getCurrentDevice() has not been implemented.');
  }

  ///获取当前已连接设备SSID
  Future<String?> getCurrentDeviceSSID() async {
    throw UnimplementedError(
        'getCurrentDeviceSSID() has not been implemented.');
  }

  ///获取当前已连接设备WIFI状态
  Future<String?> getCurrentDeviceWifiSatate() async {
    throw UnimplementedError(
        'getCurrentDeviceWifiSatate() has not been implemented.');
  }
}
